﻿using System;
using System.Collections.Generic;
using Bouyei.Geo.Converters;
using Bouyei.Geo.Geometries;
using Bouyei.Geo.GeoParsers.EsirMdb;

namespace Bouyei.Geo.GeoParsers.Parser
{
    /// <summary>
    /// 同时支持esri的.gdb和.mdb的空间信息字节解析
    /// </summary>
    public class EsriMdbParser
    {
        private GeometryReader reader = null;

        public EsriMdbParser()
        {
        }

        public unsafe Geometry FromReader(byte[] buffer, int offset = 0)
        {
            reader = new GeometryReader(buffer, offset);
            return reader.Reader();
        }
    }
}
